All Functions Used So Far, Week 4

ordered

{dplyr}

Create an ordered factor

c

{base}

Combine values/vectors into a vector

prop.test

{stats}

Test of Equal or Given Proportions

library

{base}

Load an R package

leveneTest

{car}

Computes Levene’s test for homogeneity of variance across groups.

ifelse

{base}

Return a or b depending on the value of test

ggplot

{GGPLOT2}

Create a ggplot graph

theme_classic

{GGPLOT2}

A minimalistic theme with no gridlines

geom_smooth

{GGPLOT2}

Generates a smoothed conditional means curve / line

t.test

{stats}

Performs one and two sample t-tests on vectors of data.

aes

{GGPLOT2}

Construct aesthetic mapping of a ggplot graph

read_dta

{haven}

Read a .dta file (Stata data)

read_excel

{readxl}

Read an Excel file

geom_point

{GGPLOT2}

Generates a scatter plot

setwd

{base}

Set Working Directory

chisq.test

{stats}

Chi-Squared test (e.g. for cross-tabulations)

mutate

{dplyr}

Modify/create a column in a data frame

table

{base}

Obtain frequency table of a variable/cross-tabulation of two variables

cut

{base}

Convert Numeric to Factor

summary

{base}

Obtain summary statistics or detailed regression output

with

{base}

evaluate expression in the context of a data frame

The end!